<div class="indices form">
<?php

date_default_timezone_set('Australia/Victoria');

$info = getdate();
$date = $info['mday'];
$month = $info['mon'];
$year = $info['year'];
$hour = $info['hours'];
$min = $info['minutes'];
$sec = $info['seconds'];

$current_date = "$date/$month/$year";

    if($this->Session->read('login')=='yes')
    {
        echo $this->Form->create('Index'); ?>
	    <fieldset>
		    <legend><?php echo __('Edit Index'); ?></legend>
	    <?php
	    	echo $this->Form->input('IndicesID', array('label' => 'Index ID', 'disabled' => 'true')); //readonly
		    echo $this->Form->input('IndexName', array('label' => 'Index Name', 'type' => 'select', 'options' => $indices, 'disabled' => 'true'));
		    echo $this->Form->input('Date', array('id'=>'datepicker', 'label' => 'Date of Input', 'type' => 'text', 'disabled' => 'true'));  //readonly
		    echo $this->Form->input('Weighting', array('label' => 'Weighting','type' => 'text'));

		    echo $this->Form->input('Value', array('label' => 'Value', 'type' => 'text')); 
	    ?>
	    </fieldset>
    <?php echo $this->Form->end(__('Submit')); ?>
    <?php echo $this->Form->postLink(__('Delete'), array('action' => 'delete', $this->Form->value('Index.IndicesID')), null, __('Are you sure you want to delete # %s?', $this->Form->value('Index.IndicesID'))); ?>
    </div>
<?php
}else
{
    ?>
    <p>You can't view the content in this page</p>
<?php
}
?>